🔄 sync: upstream v1.79.3-stable - #41
Conversation
* include server_tool_use in streaming usage * add test
…#16791) * fix transcription exception handling * reraise the exception
* init RAG api types * add RAG endpoints * init main.py for RAG ingest API * init RecursiveCharacterTextSplitter * add BaseRAGIngestion * fix OpenAIRAGIngestion * fix img handler * init OpenAIRAGIngestion * init BedrockRAGIngestion * init BedrockRAGIngestion * init rag tests * init BedrockVectorStoreOptions * implement BedrockRAGIngestion * add BaseRAGAPI * add endpoint for RAG ingest * add ingest RAG endpoints * add test doc * add parse_rag_ingest_request * update endpoints * docs add docs for new RAG API * fix qa check * fix linting * docs ficx * docs * add max depth checks * docs anthropic
…text-format-bridge-conversion fix: Support response_format parameter in completion -> responses bridge
- Automatically pass LiteLLM virtual key context as X-LiteLLM-* headers - Includes key_alias, user_id, team_id, org_id, and user_email - No configuration required - always enabled for application/user tracking - Excludes sensitive data (metadata, API tokens) for security - Add comprehensive tests (30 tests, all passing) - Update documentation with header details
This should allow postgres to perform a more efficient index scan instead of a sequential table scan. These two queries consistently show up in the longest-running ones in our instance, and are a major latency source for the usage page on the admin UI.
…meters (BerriAI#17019) - Add model identifier to FLASH_IMAGE_PREVIEW_MODEL_IDENTIFIERS - Add imageSize parameter support (1K, 2K, 4K) with GeminiImageSize type - Add tests for imageSize parameter transformation - Update documentation with new model
[Feature] UI - Disable edit, delete, info, for dynamically generated spend tags
[Feature] UI - User Table Sort by All
…s_fix [Feature] UI - Org Admin Team Permissions Fix
We recommend using 10–20 connections. Our actual default is 10, but the documentation incorrectly listed the default as 100.
The default is 10 seconds, not 30.
* add OPENAI_COMPATIBLE_BATCH_AND_FILES_PROVIDERS * fix use OPENAI_COMPATIBLE_BATCH_AND_FILES_PROVIDERS * add _get_batch_job_total_usage_from_file_content * fixes for vLLM + 12 labs async invoke * fix: vLLM Batch APIs * afile_retrieve * test_hosted_vllm_full_workflow * fix SERVER_URL for test
…ribute_error_code_raise Fix 500 error for malformed request
…ader_forwarding Fix: litellm user auth not passing issue
…ute_issue Add other routes in jwt auth
…7104) * docs: add Azure AI Foundry documentation for Claude models Add documentation explaining how to use Claude models (Sonnet 4.5, Haiku 4.5, Opus 4.1) deployed on Azure AI Foundry with LiteLLM. Azure exposes Claude using Anthropic's native API, so users can use the existing anthropic/ provider with their Azure endpoint. Closes BerriAI#17066 * docs: Add alternative method for Azure AI Foundry using anthropic/ provider Document that users can use anthropic/ provider with Azure endpoint as an alternative to the dedicated azure_ai/ provider.
* Update constants.py added constants * Update base_aws_llm.py added steps * Update invoke_handler.py added openai support * Update base_invoke_transformation.py added * Update test_bedrock_completion.py added
[Fix] Bedrock Guardrail Indent and Import fix
[Infra] Add Google Private API Endpoint to Vertex AI fields
Automatic sync from upstream BerriAI/litellm Preparing for v1.79.3-stable release Strategy: Merge with history preservation (main mirrors upstream)
🤖 Automated Conflict Resolution StartedClaude Code is now resolving conflicts for this PR. Process:
Status: In progress... This process may take 30-90 minutes for large PRs. |
…rges ## Changes ### carto-upstream-sync.yml - Add automatic resolver dispatch after PR creation - Check mergeable status with retries (handles GitHub's async computation) - Trigger resolver workflow when conflicts are detected ### carto-upstream-sync-resolver.yml - Add prominent merge warning at top of resolution PR body - Add warning comment step after resolution PR creation - Warn against squash/rebase merge which destroys upstream history ## Why 1. **Resolver not triggering**: GitHub doesn't fire `pull_request` events when PRs are created by workflows, even with PAT tokens. This adds explicit workflow dispatch as a reliable trigger. 2. **Squash merge prevention**: PR #26 was squash-merged, which lost all upstream commit history (4201 commits). This caused PR #41 to show inflated diff counts. Adding clear warnings to prevent this. Shortcut - Autolink: [sc-521238]
❌ Conflict Resolution FailedClaude Code encountered an error while resolving conflicts. Please check:
Workflow Run: https://github.com/CartoDB/litellm/actions/runs/19874377145 Manual Resolution Steps:
|
…rges (#43) * fix: improve upstream sync workflow reliability and prevent squash merges ## Changes ### carto-upstream-sync.yml - Add automatic resolver dispatch after PR creation - Check mergeable status with retries (handles GitHub's async computation) - Trigger resolver workflow when conflicts are detected ### carto-upstream-sync-resolver.yml - Add prominent merge warning at top of resolution PR body - Add warning comment step after resolution PR creation - Warn against squash/rebase merge which destroys upstream history ## Why 1. **Resolver not triggering**: GitHub doesn't fire `pull_request` events when PRs are created by workflows, even with PAT tokens. This adds explicit workflow dispatch as a reliable trigger. 2. **Squash merge prevention**: PR #26 was squash-merged, which lost all upstream commit history (4201 commits). This caused PR #41 to show inflated diff counts. Adding clear warnings to prevent this. Shortcut - Autolink: [sc-521238] * fix: reverse merge direction in resolver to preserve upstream commit history The previous approach (checkout carto/main, merge main INTO it) lost upstream commit history because the PR only showed Claude's resolution commits, not the upstream commits. New approach: 1. Checkout main (has all upstream commits) 2. Merge carto/main INTO it (brings CARTO customizations) 3. Resolve conflicts 4. Create PR to carto/main This ensures the resolution PR shows ALL upstream commits + resolution commits, preserving full commit history in carto/main. Also updated Claude's prompt to reflect: - Reversed conflict marker interpretation (HEAD=upstream, theirs=CARTO) - Updated ours/theirs terminology in file-specific rules - Clear explanation of why this approach preserves history
🤖 Automated Conflict Resolution StartedClaude Code is now resolving conflicts for this PR. Process:
Status: In progress... This process may take 30-90 minutes for large PRs. |
Conflict resolution strategy: - Preserved CARTO customizations in infrastructure files - Accepted upstream improvements to core LiteLLM functionality - Fixed upstream bugs in batch_utils.py (missing model_name parameter) - Fixed linting issues (unused imports, type errors, complexity warnings) Testing: - ✅ make format passed (626 files reformatted) - ✅ make lint passed (Black + Ruff checks) - ✅ make lint-mypy passed (MyPy type checking) - 🔄 make test-unit running (5221 tests with 4 parallel workers) Files resolution summary: - Accepted upstream: 631 files (core litellm, tests, docs, UI) - CARTO preserved: 0 conflicted files (CARTO workflows already non-conflicting) - Manually reviewed: 7 files (Dockerfile, Makefile, docker/Dockerfile.non_root, README.md, .circleci/config.yml, .circleci/requirements.txt, ci_cd/security_scans.sh) Key changes: - OpenAI SDK upgraded: 1.99.5 → 2.8.0 (upstream) - Added responses==0.25.7 to CircleCI requirements - Fixed batches/batch_utils.py missing model_name parameters - Fixed generic_guardrail_api.py TypedDict literal-required error - Added PLR0915 noqa comments for complex functions Total files modified: 939 (156 added, 9 modified, 81 deleted, 3 renamed, 690 from formatting)
✅ Conflict Resolution CompleteClaude Code has successfully resolved conflicts and created a resolution PR. Resolution PR: #45 Next Steps:
Workflow Run: https://github.com/CartoDB/litellm/actions/runs/19874888463 |
🔒 PR Closed - Superseded by Resolution PRThis PR has been automatically closed because conflicts have been resolved in a separate PR. Why was this closed?
Next Steps:
🤖 Automatically closed by carto-upstream-sync-resolver |
|
Conflicts resolved via #45 |
🔄 Upstream Sync: v1.79.3-stable
This PR syncs CARTO's LiteLLM fork with the latest stable upstream release.
📊 Release Information
v1.79.3-stable1.79.1🔀 Branch Flow
BerriAI/litellm:mainmerged intoCartoDB/litellm:mainCartoDB/litellm:main→CartoDB/litellm:carto/main📝 CARTO-Specific File Guidelines
When reviewing or resolving conflicts, follow these guidelines:
✅ Keep CARTO Versions (Ours)
.github/workflows/carto_*.yaml- All CARTO-specific workflows.github/workflows/carto-*.yml- CARTO workflowsCARTO_*.md- CARTO documentation filesdocs/CARTO_*.md- CARTO documentation in docs/🔄 Accept Upstream (Theirs)
pyproject.toml- Version field (should match upstream)litellm/- Core LiteLLM library codetests/- Upstream test filesrequirements.txt- Upstream dependenciesDockerfile- Check sections marked with# CARTO:commentsdocker/Dockerfile.non_root- Contains CARTO customizationsMakefile- Check sections marked with# CARTO:commentsdb_scripts/- CARTO may have custom scripts🧪 Testing Checklist
Before merging, ensure the following tests pass:
make lint- Linting passesmake test-unit- Unit tests passdocker build -f docker/Dockerfile.non_root .carto_*.yamlfiles)pyproject.tomlversion matches upstream📚 Documentation
🔧 Conflict Resolution
If this PR has conflicts, there are two options:
Option 1: Automated Claude Code Resolution (Recommended)
The carto-upstream-sync-resolver workflow will automatically trigger when conflicts are detected.
It will:
carto/mainand mergemaininto itmake lint,make lint-mypy,make test-unit)upstream-sync-resolver/<PR-number> → carto/mainWhat you need to do:
carto/mainOption 2: Manual Resolution
If you prefer manual resolution or Claude fails:
git fetch origin git checkout carto/main git pull origin carto/main git merge main # Creates conflictsResolve conflicts following guidelines above
Test your changes:
🤖 This PR was automatically created by the carto-upstream-sync workflow.